home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Arsenal Files 3
/
The Arsenal Files 3.iso
/
os2
/
os2games.exe
/
GAMEREAD.ME
< prev
next >
Wrap
Text File
|
1994-12-21
|
10KB
|
205 lines
*** OS/2 Warp Version 3.00 Chess and Klondike Game Update ***
This package contains the 12/19/94 Release Version of the OS/2 Chess
and Klondike Solitaire programs. This code may be distributed freely
to all users of OS/2 Warp.
This program Requires OS/2 Version 2.00 or later, including OS/2 Warp.
To install this code, run the INSTALL.CMD file that came with this code.
It will install the new Chess and Klondike applications over top of your
original copies. (If, for any reason, you need to restore your original
versions, you can use the Selective Install process to reinstall them
from your original OS/2 Warp diskettes or CD-ROM. I doubt you'll ever
want to do that, though.)
As you will notice, the primary enhancements over the current
OS/2 Chess and Klondike Solitaire programs are in the user interface.
Major enhancements to OS2CHESS include:
* New high-resolution bitmaps for pieces.
* 2-dimentional view.
* Context sensitive popup menus for background, board, and pieces.
(Use the right mouse button to bring up the popup menus.)
* The Menu Bar at the top of the window is now optional.
* Notebook settings (from background popup).
* Move by Drag and Drop, or Click on piece then Click on "to" square.
* Support for background bitmaps within the game window.
* Support for customizable MMPM Sound effect for events.
* Variable animation speed for piece movement.
* Support for drag-n-drop of a bitmap onto the game window,
or onto the bitmap page of the Settings Notebook.
* A new and improved Print function, to print the board and game record.
* Various performance enhancements.
Major enhancements to KLONDIKE include:
* Two 'Popup' menus for cards and for the background.
(Use the right mouse button to bring up the popup menus.)
* More flexible algorithm for dropping cards on the correct pile.
* Notebook settings (from the background popup).
* The Menu Bar is now optional.
* Support for MMPM Sound effects for various events.
* Support for 'autoflip', from the settings notebook.
* Support for background bitmaps within the game window.
* Support for custom bitmaps for card backs.
* Support for dropping a bitmap onto the game window, or on
the Background or Card Backs page of the Settings Notebook.
We have also included, in the settings notebooks, the ability to define
alternate decks of card faces (for Klondike) and piece sets (for Chess).
To do that will require building a custom DLL with bitmaps for whatever
cards or pieces you want to replace. Below are some details for
programmers on how to build such a DLL with alternate bitmaps.
We hope you enjoy this upgrade.
The A-Team,
The Applet Team of Developers within IBM.
- - - - - - - - - - (For Programmers Only) - - - - - - - - - - -
Below is a quick summary of how to go about creating alternate
Chess pieces and Klondike Card decks. You'll need to use the
Resource Compiler in order to create the final DLL file, and of course
you'll need a collection of bitmap (*.BMP) files that contain your images.
For both Chess Pieces and Klondike Cards, you must create a DLL that
contains the bitmaps to be used. It should also contain a single entry
in the string table, with the name of the set (used by the notebook page).
We recommend alternate Chess Piece files be named CHES????.DLL and Card
Decks be named CARD????.DLL, where you get to choose the last 4 characters
of the filename, but that is not required. The .DLL extension IS required.
So, your RC file should look something like this:
- - - - start of your *.RC file - - - -
#define INCL_PM
#include <os2.h>
BITMAP NUMBER1 BITMAP1.BMP
BITMAP NUMBER2 BITMAP2.BMP
... etc. - one for each bitmap ...
STRINGTABLE
BEGIN
0 "This is an alternate set of something."
END
- - - - end of your *.RC file - - - -
The string in the stringtable is used by the pieces/faces page title
to help identify the pieces/faces that you've loaded.
The only other thing you need to know are the numbers represented by NUMBER1,
NUMBER2, etc. Here are the bitmap resource numbers you need to know:
For chess, they are:
#define WHITE_PAWN 1
#define WHITE_KNIGHT 2
#define WHITE_BISHOP 3
#define WHITE_ROOK 4
#define WHITE_QUEEN 5
#define WHITE_KING 6
#define BLACK_PAWN 7 /* Black pieces are optional. */
#define BLACK_KNIGHT 8
#define BLACK_BISHOP 9
#define BLACK_ROOK 10
#define BLACK_QUEEN 11
#define BLACK_KING 12
These define the 3D pieces used. The 2D pieces are numbered likewise,
starting at 13 and continuing up to 24. Right now, the black pieces are
actually generated from the white resources, so you actually only have to
provide bitmaps for the white pieces. It is (or should be - it currently
doesn't yet work) possible to have black and white pieces shaped
differently, but for now you can just provide the white pieces and we will
shade the black pieces accordingly. So, for a complete chess set, provide
the 3-D views as resources 1-6, and the 2-D views as resources 13-18.
We do not currently support separate black resources.
For Klondike, cards are numbered starting at the 2 of Hearts (card number
1) up through the Ace of Hearts (card 13), then likewise for Spades
(14-26), Diamonds (27-39), and finally Clubs (40-52). There are actually
two copies of the card bitmaps stored, one for VGA 16-color and one for 256
color modes. For the VGA versions, add 4300 to the numbers (4301-4352),
and for the 256-color versions, add 4400 to them (4401-4452).
In Klondike, specifying an alternate deck of card faces also allows you to
replace the 9 default card backs as well, if you so desire. ID numbers of
4101-4109 are the 9 default card backs for VGA, 4121-4129 are smaller
versions of those card backs, used to place on the buttons. For higher
resolutions, 4201-4209 represent the actual card backs, 4221-4229 the
smaller versions for buttons. So, we have 4 sets of bitmaps here. The
'full' bitmap for both 16 and 256 colors, and the 'small' bitmaps for use
on the buttons for both color sets.
For both Klondike and Chess, failure to specify any particular resource in
your DLL will cause the code to go look for the default bitmap from the EXE
file and will use that instead. For Klondike, bitmaps are provided for the
12 face cards and the Ace of Spades. All other cards are drawn by the
program. But, if a bitmap is specified for that card, the bitmap will be
used and the drawing routine bypassed. In chess, if you were to specify a
new default 3-D set without their 2-D equivalents, the standard 2-D set
would be used for that view.
In all cases, there are some special considerations when creating your
bitmaps. First and foremost, is size. Although any bitmap size should
work, we recommend sticking with our same default sizes. For Klondike,
larger bitmaps will simply cause the code to slow down greatly whenever the
card is drawn. For chess, non-standard sizes can cause problems, unless
it is an exact multiple of the default. (32x64 is the default for 3D,
so 64x128 should also work, but 48x96 may not. This is a temporary
restriction.) So use larger bitmaps at your own risk in Klondike, but
for Chess, please be sure to stick with our default sizes, or even multiples
thereof.
Recommended sizes for bitmaps are:
Klondike:
VGA Card Face: 36x60 (16 colors)
Hires Card Face: 54x90 (256 colors)
Card Back VGA Bitmap: 72x108 (16 colors)
Card Back VGA Button: 36x54 (16 colors)
Card Back Hires Bitmap: 72x108 (256 colors)
Card Back Hires Button: 36x54 (256 colors)
Chess:
3D Pieces: 32x64 (256 colors)
2D Pieces: 32x32 (256 colors)
Another tidbit of info on Chess bitmaps has to do with the background
and the image. The pixel at the lower-left corner of the bitmap is used to
identify the background color, which is 'seen through' when displaying the
piece. Please be sure to use that color for all non-piece pixels to get
the proper show-through effect. Also, the code that determines the region
for the piece (used to click on the piece) assumes the piece is one solid
object, not two separate parts, one floating on top of or sitting beside
the other. It also doesn't support 'holes' or windows showing through in
the middle of the piece. So, please be sure your pieces are one solid
object, not a collection of parts. (You can still create images that appear
to be floating on top of the other parts, as long as they are actually
connected through shadows or other non-background-color pixels.)
Also, for best shading effect, we also recommend you generate your pieces to
be black-and-white (with shades of grey) images, not color images. We allow
the user to control the color of the pieces from the Colors Dialog, so we
do not currently support multi-colored and fixed-colored pieces.
That should do it! That's all the gory details you need to know in order
to create your own card face or chess piece DLL files. So, start rounding
up your spare bitmaps, and start creating alternate cards and pieces!
Finally, if you do generate a nice Chess Piece set or a nice Card Face set,
(without any possible copyright infringements!) then we would ask you toto
make you work available for others to download off of the internet.
We'll be looking for some a nice collections of alternative sets.
We hope you enjoy this upgrade, and we look forward to seeing what
kind of alternate card or piece sets that y'all come up with.
Cheers,
The General, Robert E. Lee Jr.
Member: The A-Team.